<?php
/**
 * Created by PhpStorm.
 * Clerk: Administrator
 * Date: 2018/8/22
 * Time: 10:44
 */

namespace app\api\controller\v1;
use app\api\controller\BaseController;
use think\cache\driver\Redis;

class Test extends BaseController
{
    public function index($id = 0)
    {

        return json_failed(100001);

    }

    public function testRedisSet(){
        $redis = new Redis();
        $c = $redis->set('uid1','111');
        dump($c);
    }
    public function testRedisGet(){
        $redis = new Redis();
        $c = $redis->get('uid1paperorder1');
        return $c;
    }

    public function testRedisTtl(){
        $redis = new Redis();
        $c = $redis->ttl('uid1paperorder1');
        return $c;
    }


}